package cn.huiyunche.base.service.interfaces;

import cn.huiyunche.base.service.model.SysVersionNote;
import cn.huiyunche.base.service.vo.Result;
import cn.huiyunche.tools.basic.exceptions.BusinessException;

import java.util.List;

/**
 * Created by LYN on 6/18/16.
 */
public interface VersionService {

    /**
     * 获取IOS最新版本
     *
     * @return
     */
    SysVersionNote getLasterVersionIOS(String platform);

    /**
     * 获取Android最新版本
     *
     * @return
     */
    SysVersionNote getLasterVersionAndroid(String platform);

    /**
     * 查询版本列表
     *
     * @return
     * @throws BusinessException
     */
    Result<List<SysVersionNote>> list() throws Exception;

    /**
     * 数据修改
     *
     * @param versionNote
     * @return
     * @throws BusinessException
     */
    Result<Object> modifyVersion(SysVersionNote versionNote) throws Exception;

    /**
     * 删除版本号
     *
     * @param id
     * @return
     * @throws BusinessException
     */
    Result<Object> deleteVersion(Long id) throws Exception;

    /**
     * 根据ID查询版本信息
     *
     * @param id
     * @return
     * @throws BusinessException
     */
    SysVersionNote selectVersionId(Long id) throws Exception;

}
